package com.cskaoyan.mapper;

import com.cskaoyan.bean.CskaoyanmallUser;
import com.cskaoyan.bean.CskaoyanmallUserExample;
import java.util.List;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

@Mapper
public interface CskaoyanmallUserMapper {
    long countByExample(CskaoyanmallUserExample example);

    int deleteByExample(CskaoyanmallUserExample example);

    /**
     * delete by primary key
     * @param id primaryKey
     * @return deleteCount
     */
    int deleteByPrimaryKey(Integer id);

    /**
     * insert record to table
     * @param record the record
     * @return insert count
     */
    int insert(CskaoyanmallUser record);

    /**
     * insert record to table selective
     * @param record the record
     * @return insert count
     */
    int insertSelective(CskaoyanmallUser record);

    List<CskaoyanmallUser> selectByExample(CskaoyanmallUserExample example);

    /**
     * select by primary key
     * @param id primary key
     * @return object by primary key
     */
    CskaoyanmallUser selectByPrimaryKey(Integer id);

    int updateByExampleSelective(@Param("record") CskaoyanmallUser record, @Param("example") CskaoyanmallUserExample example);

    int updateByExample(@Param("record") CskaoyanmallUser record, @Param("example") CskaoyanmallUserExample example);

    /**
     * update record selective
     * @param record the updated record
     * @return update count
     */
    int updateByPrimaryKeySelective(CskaoyanmallUser record);

    /**
     * update record
     * @param record the updated record
     * @return update count
     */
    int updateByPrimaryKey(CskaoyanmallUser record);

    Integer[] selectUserStat();


    Long selectNum();


    String selectUserNameById(Integer userId);


    Integer selectCount101(Integer userId);

    Integer selectCount201(Integer userId);

    Integer selectCount301(Integer userId);

    Integer selectCount401(Integer userId);

    Integer selectCount401();


    Integer seleceIdByUsername(@Param("name") String name);

    CskaoyanmallUser selectUserByMobile(String mobile);


    CskaoyanmallUser selectOneByUserName(String principal);


    Integer selectCount101id(int id);

    Integer selectCount201id(int id);

    Integer selectCount301id(int id);

    Integer selectCount401id(int id);
}